import React, { Fragment } from 'react';
import { connect } from 'dva';
import { Form, Input, Button, Select, Divider, Col, Row, Card } from 'antd';
import router from 'umi/router';
import styles from './style.less';
import DescriptionList from '@/components/DescriptionList';

import {
  enterpriseNature,
  enterpriseCharacter,
  enterpriseType,
  taxType,
  industryClassification,
  relationType,
  listed,
  economicType,
} from '../../../../common/selectOption';

const { Description } = DescriptionList;
const { Option } = Select;
const { TextArea } = Input;

const formItemLayout = {
  labelCol: {
    span: 7,
  },
  wrapperCol: {
    span: 17,
  },
};

@connect(({ packing }) => ({
  packing,
}))
@Form.create()
class baseInfo extends React.PureComponent {
  state = {
    data: {},
  };

  constructor(props) {
    super(props);
  }

  componentWillMount() {

  }

  render() {
    const { borrow } = this.props;
    return [
      <Card title="借款人信息" bordered={false} style={{ marginBottom: 20 }}>
        <div>
          <DescriptionList title="借款人基本信息" size="large" style={{ marginBottom: 32 }}>
            <Description term="借款人类型">{borrow.borrowType}</Description>
            <Description term="借款企业">{borrow.enterpriseName}</Description>
            <Description term="统一社会信用代码">{borrow.creditCode}</Description>
            <Description term="法定代表人">{borrow.legal}</Description>
            <Description term="经营范围">{borrow.scope}</Description>
            <Description term="注册资本(万元)">{borrow.capital}</Description>
            <Description term="成立时间">{borrow.buildTime}</Description>
            <Description term="注册地址">{borrow.address}</Description>
            <Description term="办公地址">{borrow.workSpace}</Description>
            <Description term="所属行业">{borrow.industry}</Description>
            <Description term="主营业务">{borrow.operation}</Description>
            <Description term="经营区域">{borrow.managementArea}</Description>
            <Description term="从业年限">{borrow.entirePeriod}</Description>
            <Description term="股东信息">{borrow.shareHolder}</Description>
          </DescriptionList>
          <DescriptionList title="借款人在平台借款情况" size="large" style={{ marginBottom: 32 }}>
            <Description term="累计借款笔数">{borrow.borrowTimes}</Description>
            <Description term="累计借款金额">{borrow.borrowAmount}</Description>
            <Description term="累计逾期次数">{borrow.overdueTimes}</Description>
            <Description term="待还金额">{borrow.repaymentAmount}</Description>
            <Description term="在其他网络借贷平台借款情况">{borrow.other}</Description>
          </DescriptionList>
        </div>

      </Card>,

    ];
  }
}

export default baseInfo;
